<?php
	echo '<form class="login_form" method="post" name="logoutlogin" action="index.php">
    	   <table class="fill">
    	       <tr>';       
    if(isset($_SESSION['loggedin'])&& isset($_SESSION['name'])){
        echo '
        <td class="right">
            <input class="btn" name="logout" type="submit" value="'.$lang["LOGOUT"].' ['.$_SESSION['name'].']"/>
        </td>';
    }else {
        echo '
        <td>
            <table class="fill">
                <tr>
                    <th>
            			'.$lang["LOGIN"].':
            		</th>
            		<td>
            			<input type="text" name="login"/>
            		</td>
                </tr>
                <tr>
                    <th>
            			'.$lang["PASSWORD"].':
            		</th>
            		<td>
            			<input type="password" name="pass"/>
            		</td>
                </tr>
            </table>
        </td>
        <td>
            <input class="btn" type="submit" name="dologin" value="'.$lang['LOGIN'].'"/>
		</td>
        ';
    }
    echo'
                </tr>
            </table>
        </form>';
?>